<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    {include file="/layout/scriptload"}
    <title>系统管理</title>
</head>
<body>
<div class="box">
    <!-- /.box-header -->
    <section class="content">
        <div class="box-body">
            <form role="form">
                <div class="form-group col-md-7">
                    <label>发送效果：<span style="color: orange;">（如果修改，请重新配置模板）</span></label>
                </div>
                <div class="form-group col-md-7" style="min-height: 300px;border:1px solid #333333;">
                    {if condition="$data['type'] == 1"}
                    <div class="form-group col-md-7" style="padding: 0px;font-weight: bold;margin-top: 7px">
                        <labe>预约成功提醒</label>
                    </div>
                    <div class="form-group col-md-7" style="padding: 0px;">
                        <label style="color: {$data.color_detail};">{$data.content_detail}</label>
                    </div>
                    <div class="form-group col-md-7" style="padding: 0px;">
                        <label>预约时间：<span style="color: {$data.color_detail};" >{$data.appointment_time}</span></label>
                    </div>
                    <div class="form-group col-md-7" style="padding: 0px;">
                        <label>预约场馆：<span style="color: {$data.color_place};" >{$data.appointment_place}</span></label>
                    </div>
                    <div class="form-group col-md-7" style="padding: 0px;">
                        <label>约定对象：<span style="color: {$data.color_user};" >{$data.appointment_user}</span></label>
                    </div>
                    <div class="form-group col-md-7" style="padding: 0px;">
                        <label>其他原因：<span style="color: {$data.color_reason};" >{$data.reason}</span></label>
                    </div>
                    <div class="form-group col-md-7" style="padding: 0px;">
                        <label style="color: {$data.color_remark};">{$data.remark}</label>
                    </div>
                    {/if}
                    {if condition="$data['type'] == 2"}
                        <div class="form-group col-md-7" style="padding: 0px;font-weight: bold;margin-top: 7px">
                            <labe>预约成功通知</label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label style="color: {$data.color_detail};">{$data.content_detail}</label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label>预约内容：<span style="color: {$data.color_content};" >{$data.appointment_content}</span></label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label>开始时间：<span style="color: {$data.color_place};" >{$data.begin_time}</span></label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label><span style="color: {$data.color_remark};" >{$data.remark}</span></label>
                        </div>
                    {/if}
                    {if condition="$data['type'] == 3"}
                        <div class="form-group col-md-7" style="padding: 0px;font-weight: bold;margin-top: 7px">
                            <labe>预约成功通知</label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label style="color: {$data.color_detail};">{$data.content_detail}</label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label>预约内容：<span style="color: {$data.color_content};" >{$data.appointment_content}</span></label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label>开始时间：<span style="color: {$data.color_begin};" >{$data.begin_time}</span></label>
                        </div>
                        <div class="form-group col-md-7" style="padding: 0px;">
                            <label><span style="color: {$data.color_remark};" >{$data.remark}</span></label>
                        </div>
                    {/if}
                </div>
                <div class="form-group col-md-7">
                    <label>发送模式</label>
                    <select id="select" class="form-control select2" style="width: 120px;">
                        <option value="1" selected="selected">测试发生</option>
                        <option value="2">立即发生</option>
                        <option value="3">定时发生</option>
                    </select>
                </div>
                <div class="form-group col-md-7" id="openiddiv">
                    <label>测试openId</label>
                    <input type="text" id="openid" class="form-control" placeholder="openId...">
                </div>
                <div class="form-group col-md-7" id="sendtimediv" style="display: none;">
                    <label>定时发送</label>
                    <input type="text" id="sendtime" class="form-control" placeholder="选择时间...">
                </div>
                <div class="form-group col-md-7">
                    <div id="btn_add" class="btn btn-info btn-flat pull-right">确定发送</div>
                </div>
            </form>
        </div>
    <!-- /.box-body -->
    </section>
</div>
</body>
<script>
    layui.use('laydate', function(){
        var laydate = layui.laydate;

        //执行一个laydate实例
        laydate.render({
            elem: '#sendtime' //指定元素
            ,type:'datetime'
        });
    });
    $(function(){
        $('#select').change(function(){
            var _val = $(this).val();
            if(_val == 1){
                $('#openiddiv').show();
                $('#sendtimediv').hide();
            }else if(_val == 2){
                $('#openiddiv').hide();
                $('#sendtimediv').hide();
            }else if(_val == 3){
                $('#openiddiv').hide();
                $('#sendtimediv').show();
            }
        })
    })
</script>
</html>